package com.th.supcom.pds.impl.service.internal.phamapply.command;

import java.util.List;
import java.util.Map;

import org.apache.commons.chain.impl.ContextBase;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.th.supcom.pds.domain.pojo.InpPhamApplyDetailSummary;
import com.th.supcom.pds.domain.pojo.InpPhamApplyMaster;
import com.th.supcom.pds.domain.pojo.InpPhamApplyPatInfo;
import com.th.supcom.pds.domain.pojo.InpPhamDispenseDetail;
import com.th.supcom.pds.domain.pojo.PdsPatPhamRemain;
import com.th.supcom.pds.domain.vo.InpPhamApplyDetailVO;
import com.th.supcom.pds.domain.vo.InpPhamDispenseDetailVO;

/**
 * 住院摆药 command chain context 参数
 * 
 * @author leaqua@qq.com
 */
public class PhamDispenseContext extends ContextBase
{
    private static final long serialVersionUID = 1L;
    /** 请领护理单元 */
    private String m_nurseUnitCode;
    /** 执行药房 */
    private String m_dispensary;
    /** 摆药请领明细 */
    private List <InpPhamApplyDetailVO> m_applyDetailVOList;
    /** 摆药请领主记录 */
    private InpPhamApplyMaster m_inpPhamApplyMaster;
    /** 药品基本信息List */
    private List <InpPhamApplyDetailSummary> m_phamInfoList;
    /** 药品基本信息Map */
    private Map <String, InpPhamApplyDetailSummary> m_phamInfoMap;
    /** 摆药执行明细 */
    private List <InpPhamDispenseDetailVO> m_inpPhamDispenseDetailVOList;
    /** 将摆药执行明细按照患者住院流水号分组 */
    private Map <Long, List <InpPhamDispenseDetailVO>> m_dispenseDetailByPaiVisitId;
    /** 将摆药执行明细按照药品标准码分组 */
    private Map <String, List <InpPhamDispenseDetailVO>> m_dispenseDetailByPhamStdCode;
    /** 患者基本信息 */
    private Map <Long, InpPhamApplyPatInfo> m_patMap;
    /** 未摆药清单 */
    private List <InpPhamApplyDetailVO> m_notDispenseApplyDetailList;
    /** 将摆药药品标准码List */
    private List <String> m_phamStdCodeList;
    /** 患者住院流水号List */
    private List <Long> m_paiVisitIdList;
    /** 患者剩余药品数量 */
    private Map <Long, Map <String, PdsPatPhamRemain>> m_patPhamRemainMap;
    /** 操作人 */
    private String m_operator;
    /** 已冲抵的摆药执行明细 */
    private List <InpPhamDispenseDetail> m_offsetedDispenseDetail;
    /** 已冲抵的摆药请领明细 */
    private List <InpPhamApplyDetailVO> m_offsetedApplyDetail;
    /** 已转向的摆药请领明细 */
    private List <InpPhamApplyDetailVO> m_changeDispensaryApplyDetail;

    /** 摆药数量为零的执行记录 */
    private List <InpPhamDispenseDetailVO> m_zeroPhamDispenseDetailList;

    /** 摆药数量为零及不为零的执行记录 */
    private List <InpPhamDispenseDetailVO> totalDispenseList;

    /**
     * 退药方式 Y：又要退药 N:无药退药
     */
    private String m_withdrawType;

    /**
     * 获取totalDispenseList
     * 
     * @return the totalDispenseList
     */
    public List <InpPhamDispenseDetailVO> getTotalDispenseList ()
    {

        return totalDispenseList;
    }

    /**
     * 获取totalDispenseList
     * 
     * @param totalDispenseList the totalDispenseList to set.
     */
    public void setTotalDispenseList (List <InpPhamDispenseDetailVO> totalDispenseList)
    {

        this.totalDispenseList = totalDispenseList;
    }

    /**
     * 获取zeroPhamDispenseDetailList
     * 
     * @return the zeroPhamDispenseDetailList
     */
    public List <InpPhamDispenseDetailVO> getZeroPhamDispenseDetailList ()
    {

        return m_zeroPhamDispenseDetailList;
    }

    /**
     * 获取zeroPhamDispenseDetailList
     * 
     * @param zeroPhamDispenseDetailList the zeroPhamDispenseDetailList to set.
     */
    public void setZeroPhamDispenseDetailList (List <InpPhamDispenseDetailVO> zeroPhamDispenseDetailList)
    {

        m_zeroPhamDispenseDetailList = zeroPhamDispenseDetailList;
    }

    /**
     * 获取changeDispensaryApplyDetail
     * 
     * @return the changeDispensaryApplyDetail
     */
    public List <InpPhamApplyDetailVO> getChangeDispensaryApplyDetail ()
    {

        return m_changeDispensaryApplyDetail;
    }

    /**
     * 获取changeDispensaryApplyDetail
     * 
     * @param changeDispensaryApplyDetail the changeDispensaryApplyDetail to
     *            set.
     */
    public void setChangeDispensaryApplyDetail (List <InpPhamApplyDetailVO> changeDispensaryApplyDetail)
    {

        m_changeDispensaryApplyDetail = changeDispensaryApplyDetail;
    }

    /**
     * 获取offsetedApplyDetail
     * 
     * @return the offsetedApplyDetail
     */
    public List <InpPhamApplyDetailVO> getOffsetedApplyDetail ()
    {

        return m_offsetedApplyDetail;
    }

    /**
     * 获取offsetedApplyDetail
     * 
     * @param offsetedApplyDetail the offsetedApplyDetail to set.
     */
    public void setOffsetedApplyDetail (List <InpPhamApplyDetailVO> offsetedApplyDetail)
    {

        m_offsetedApplyDetail = offsetedApplyDetail;
    }


    /**
     * 获取退药方式
     * 
     * @return
     */
    public String getWithdrawType ()
    {
        return m_withdrawType;
    }

    /**
     * 设置退药方式
     * 
     * @param withdrawType
     */
    public void setWithdrawType (String withdrawType)
    {
        this.m_withdrawType = withdrawType;
    }

    /**
     * 获取操作人
     * 
     * @return
     */
    public String getOperator ()
    {
        return m_operator;
    }

    /**
     * 设置操作人
     * 
     * @param operator
     */
    public void setOperator (String operator)
    {
        this.m_operator = operator;
    }

    /**
     * 获取nurseUnitCode
     * 
     * @return the nurseUnitCode
     */
    public String getNurseUnitCode ()
    {

        return m_nurseUnitCode;
    }

    /**
     * 获取nurseUnitCode
     * 
     * @param nurseUnitCode the nurseUnitCode to set.
     */
    public void setNurseUnitCode (String nurseUnitCode)
    {

        m_nurseUnitCode = nurseUnitCode;
    }

    /**
     * 获取dispensary
     * 
     * @return the dispensary
     */
    public String getDispensary ()
    {

        return m_dispensary;
    }

    /**
     * 获取dispensary
     * 
     * @param dispensary the dispensary to set.
     */
    public void setDispensary (String dispensary)
    {

        m_dispensary = dispensary;
    }

    /**
     * 获取applyDetailVOList
     * 
     * @return the applyDetailVOList
     */
    public List <InpPhamApplyDetailVO> getApplyDetailVOList ()
    {

        return m_applyDetailVOList;
    }

    /**
     * 获取applyDetailVOList
     * 
     * @param applyDetailVOList the applyDetailVOList to set.
     */
    public void setApplyDetailVOList (List <InpPhamApplyDetailVO> applyDetailVOList)
    {

        m_applyDetailVOList = applyDetailVOList;
    }

    /**
     * 获取inpPhamApplyMaster
     * 
     * @return the inpPhamApplyMaster
     */
    public InpPhamApplyMaster getInpPhamApplyMaster ()
    {

        return m_inpPhamApplyMaster;
    }

    /**
     * 获取inpPhamApplyMaster
     * 
     * @param inpPhamApplyMaster the inpPhamApplyMaster to set.
     */
    public void setInpPhamApplyMaster (InpPhamApplyMaster inpPhamApplyMaster)
    {

        m_inpPhamApplyMaster = inpPhamApplyMaster;
    }

    /**
     * 获取phamInfoList
     * 
     * @return the phamInfoList
     */
    public List <InpPhamApplyDetailSummary> getPhamInfoList ()
    {

        return m_phamInfoList;
    }

    /**
     * 获取phamInfoList
     * 
     * @param phamInfoList the phamInfoList to set.
     */
    public void setPhamInfoList (List <InpPhamApplyDetailSummary> phamInfoList)
    {

        m_phamInfoList = phamInfoList;
    }

    /**
     * 获取phamInfoMap
     * 
     * @return the phamInfoMap
     */
    public Map <String, InpPhamApplyDetailSummary> getPhamInfoMap ()
    {

        return m_phamInfoMap;
    }

    /**
     * 获取phamInfoMap
     * 
     * @param phamInfoMap the phamInfoMap to set.
     */
    public void setPhamInfoMap (Map <String, InpPhamApplyDetailSummary> phamInfoMap)
    {

        m_phamInfoMap = phamInfoMap;
    }

    /**
     * 获取inpPhamDispenseDetailVOList
     * 
     * @return the inpPhamDispenseDetailVOList
     */
    public List <InpPhamDispenseDetailVO> getInpPhamDispenseDetailVOList ()
    {

        return m_inpPhamDispenseDetailVOList;
    }

    /**
     * 获取inpPhamDispenseDetailVOList
     * 
     * @param inpPhamDispenseDetailVOList the inpPhamDispenseDetailVOList to
     *            set.
     */
    public void setInpPhamDispenseDetailVOList (List <InpPhamDispenseDetailVO> inpPhamDispenseDetailVOList)
    {

        m_inpPhamDispenseDetailVOList = inpPhamDispenseDetailVOList;
    }

    /**
     * 获取dispenseDetailByPaiVisitId
     * 
     * @return the dispenseDetailByPaiVisitId
     */
    public Map <Long, List <InpPhamDispenseDetailVO>> getDispenseDetailByPaiVisitId ()
    {

        return m_dispenseDetailByPaiVisitId;
    }

    /**
     * 获取dispenseDetailByPaiVisitId
     * 
     * @param dispenseDetailByPaiVisitId the dispenseDetailByPaiVisitId to set.
     */
    public void setDispenseDetailByPaiVisitId (Map <Long, List <InpPhamDispenseDetailVO>> dispenseDetailByPaiVisitId)
    {

        m_dispenseDetailByPaiVisitId = dispenseDetailByPaiVisitId;
    }

    /**
     * 获取dispenseDetailByPhamStdCode
     * 
     * @return the dispenseDetailByPhamStdCode
     */
    public Map <String, List <InpPhamDispenseDetailVO>> getDispenseDetailByPhamStdCode ()
    {

        return m_dispenseDetailByPhamStdCode;
    }

    /**
     * 获取dispenseDetailByPhamStdCode
     * 
     * @param dispenseDetailByPhamStdCode the dispenseDetailByPhamStdCode to
     *            set.
     */
    public void setDispenseDetailByPhamStdCode (Map <String, List <InpPhamDispenseDetailVO>> dispenseDetailByPhamStdCode)
    {

        m_dispenseDetailByPhamStdCode = dispenseDetailByPhamStdCode;
    }

    /**
     * 获取patMap
     * 
     * @return the patMap
     */
    public Map <Long, InpPhamApplyPatInfo> getPatMap ()
    {

        return m_patMap;
    }

    /**
     * 获取patMap
     * 
     * @param patMap the patMap to set.
     */
    public void setPatMap (Map <Long, InpPhamApplyPatInfo> patMap)
    {

        m_patMap = patMap;
    }

    /**
     * 获取notDispenseApplyDetailList
     * 
     * @return the notDispenseApplyDetailList
     */
    public List <InpPhamApplyDetailVO> getNotDispenseApplyDetailList ()
    {

        return m_notDispenseApplyDetailList;
    }

    /**
     * 获取notDispenseApplyDetailList
     * 
     * @param notDispenseApplyDetailList the notDispenseApplyDetailList to set.
     */
    public void setNotDispenseApplyDetailList (List <InpPhamApplyDetailVO> notDispenseApplyDetailList)
    {

        m_notDispenseApplyDetailList = notDispenseApplyDetailList;
    }

    /**
     * 获取phamStdCodeList
     * 
     * @return the phamStdCodeList
     */
    public List <String> getPhamStdCodeList ()
    {

        return m_phamStdCodeList;
    }

    /**
     * 获取phamStdCodeList
     * 
     * @param phamStdCodeList the phamStdCodeList to set.
     */
    public void setPhamStdCodeList (List <String> phamStdCodeList)
    {

        m_phamStdCodeList = phamStdCodeList;
    }

    /**
     * 获取paiVisitIdList
     * 
     * @return the paiVisitIdList
     */
    public List <Long> getPaiVisitIdList ()
    {

        return m_paiVisitIdList;
    }

    /**
     * 获取paiVisitIdList
     * 
     * @param paiVisitIdList the paiVisitIdList to set.
     */
    public void setPaiVisitIdList (List <Long> paiVisitIdList)
    {

        m_paiVisitIdList = paiVisitIdList;
    }

    /**
     * 获取patPhamRemainMap
     * 
     * @return the patPhamRemainMap
     */
    public Map <Long, Map <String, PdsPatPhamRemain>> getPatPhamRemainMap ()
    {

        return m_patPhamRemainMap;
    }

    /**
     * 获取patPhamRemainMap
     * 
     * @param patPhamRemainMap the patPhamRemainMap to set.
     */
    public void setPatPhamRemainMap (Map <Long, Map <String, PdsPatPhamRemain>> patPhamRemainMap)
    {

        m_patPhamRemainMap = patPhamRemainMap;
    }

    /**
     * 获取offsetedDispenseDetail
     * 
     * @return the offsetedDispenseDetail
     */
    public List <InpPhamDispenseDetail> getOffsetedDispenseDetail ()
    {

        return m_offsetedDispenseDetail;
    }

    /**
     * 获取offsetedDispenseDetail
     * 
     * @param offsetedDispenseDetail the offsetedDispenseDetail to set.
     */
    public void setOffsetedDispenseDetail (List <InpPhamDispenseDetail> offsetedDispenseDetail)
    {

        m_offsetedDispenseDetail = offsetedDispenseDetail;
    }

    /** 日志记录器. */
    public static final Logger s_logger = LoggerFactory.getLogger (PhamDispenseContext.class);

    /** 公司版权信息. */
    public static final String copyright = "Copyright 2014, TH Supcom Corporation";

    /** 提交路径. */
    public static final String SCC_BRANCH = "$URL$";

    /** 提交日期. */
    public static final String SCC_LAST_MODIFICATION_DATE = "$Date$";

    /** 最终修改人员. */
    public static final String SCC_LAST_MODIFIER_NAME = "$Author$";

    /** 最终版本号. */
    public static final String SCC_REVISION = "$Revision$";
}
